package lumingweihua.future.cn.lumingweihua.ui.mine;

import android.os.Bundle;
import android.support.annotation.Nullable;
import android.webkit.WebView;

import com.zhusx.core.interfaces.IHttpResult;
import com.zhusx.core.network.HttpRequest;

import butterknife.BindView;
import butterknife.ButterKnife;
import lumingweihua.future.cn.lumingweihua.R;
import lumingweihua.future.cn.lumingweihua.network.LoadData;
import lumingweihua.future.cn.lumingweihua.network.LoadingHelper;
import lumingweihua.future.cn.lumingweihua.ui.BaseCompatActivity;

/**
 * todo 使用指南
 * Author       zhusx
 * Created      2018/3/19 14:59
 */

public class UseManagerActivity extends BaseCompatActivity {
    @BindView(R.id.webView)
    WebView webView;

    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_mine_use);
        ButterKnife.bind(this);
        LoadData<String> loadData = new LoadData<>(LoadData.Api.个人中心使用指南, this);
        loadData._setOnLoadingListener(new LoadingHelper<String>(webView, loadData) {
            @Override
            public void __onComplete(HttpRequest<Object> request, IHttpResult<String> t) {
                webView.loadUrl(t.getData());
            }
        });
        loadData._loadData();
    }
}
